home *** CD-ROM | disk | FTP | other *** search
/ BBS in a Box 7 / BBS in a Box - Macintosh - Volume VII (BBS in a Box) (January 1993).iso / Files / Prog / T / THINK Back 1.1.cpt / ReadMe next >
Text File  |  1992-07-07  |  5KB  |  123 lines

  1. THINK Back 1.1
  2.  
  3. Copyright © 1991,1992 Phil Shapiro
  4. All Rights Reserved
  5.  
  6. Description
  7.  
  8. This Extension enables you to compile in the background using THINK C or
  9. THINK Pascal under System 7.0. If a compile finishes when the compiler is
  10. in the background, the Notification Manager will be used to tell you that it's
  11. done.
  12.  
  13. Installation and Use
  14.  
  15. Drop THINK Back in your Extensions folder and restart. To start a
  16. backgroundable compile, hold down the shift key when choosing any THINK C
  17. or THINK Pascal action that will cause a source file to be compiled. THINK
  18. Back will change the compiler's progress dialog to a movable modal dialog
  19. box if it was proprly activated.
  20.  
  21. For example, if you bring up the THINK C Make dialog box and hold down the
  22. shift key while clicking on the Make button, THINK Back will be activated. It
  23. will also be activated if you press command-shift-U instead of just
  24. command-U. In Pascal, press command-shift-B, "Bring Up to Date". You can
  25. use command-period to cancel a compile as usual. THINK Back will refuse to
  26. install itself if any of its needed resources are missing, or if you try to use
  27. it under System 6.
  28.  
  29. Customizing
  30.  
  31. There's no Control Panel interface for this yet, so you'll have to use ResEdit
  32. if you want to customize THINK Back's behavior. You can edit the PREF
  33. resource using the template provided. You can change:
  34.  
  35.    • The number of ticks that THINK C or THINK Pascal passes to
  36.    WaitNextEvent when it's in the foreground or background. Using this, you
  37.    can fine-tune it's performance on your machine. The default settings (5
  38.    ticks in the foreground, 15 in the background) should provide good
  39.    performance on a IIsi.
  40.  
  41.    • If THINK Back is on or off by default. If it's on by default, then you
  42.    can disable it by holding down the shift key when starting a compile. If
  43.    it's off by default, then THINK Back will not be activated unless you hold
  44.    down the shift key when starting a compile. The default setting is off by
  45.    default.
  46.  
  47.    • The level of notification. There are four settings:
  48.  
  49.       0 - no notification at all
  50.       1 - mark the compiler in the Application menu with a diamond
  51.       2 - mark the compiler and display a rotating icon in the Application
  52.       menu
  53.       3 - mark the compiler, display a rotating icon, and present an alert to
  54.       let you know that it's finished compiling
  55.  
  56.    The default setting is level 2.
  57.    
  58.    • The number of milliseconds between calls to WaitNextEvent. The default
  59.    setting is 400ms; you can use this number to make THINK C or Pascal as
  60.    multi-finder friendly or unfriendly as you like.
  61.  
  62. If you change the PREF resource, changes will take effect the next time you
  63. boot your Macintosh.
  64.  
  65. How it works
  66.  
  67. At INIT time, THINK Back installs a global head patch on the _GetNewDialog
  68. trap. This trap watches each call to GetNewDialog and looks for the THINK C
  69. or THINK Pascal Progress dialog box. When it sees this dialog, it installs a
  70. number of other patches local to the compler's heap, one of which calls
  71. WaitNextEvent. When the compile is finished, all of the installed patches
  72. are removed (except the one on _GetNewDialog). The code is loaded low in
  73. the System heap, and it plus its data take up less than 3K.
  74.  
  75. Bugs/Odd Features
  76.  
  77. Since the same dialog is used for different things in THINK C, this patch
  78. will also background Multi-File Search, Precompile, Check Syntax,
  79. Disassemble and Preprocess. The same is true for THINK Pascal and its
  80. Multi-File Search dialog.
  81.  
  82. Credits
  83.  
  84. ShowIconFamily by Patrick C. Beard
  85. StartupError by joe holt
  86.  
  87. Version History
  88.  
  89. 1.1   - supports both THINK C and THINK Pascal (!)
  90.         - uses a Time Manager task to schedule when to call WaitNextEvent.
  91.         This allows for much better control of performance. (Idea courtesy
  92.         Juri Munkki.)
  93.         - icon manager calls are used for notification icons; now the notify
  94.         icon will be in color.
  95. 1.0.1 - calls WaitNextEvent less often when THINK C is in the foreground.
  96.          When it's placed in the background, WaitNextEvent is called as often
  97.          as before.
  98.         - disallows reentrant use (you can't background two compiles at the
  99.         same time)
  100.         - disables CMaster's menu (if present) during compiles
  101.         - uses a much more reliable method to tell if THINK C is in the
  102.         background or not. This fixes the bug where THINK C would hang after
  103.         switching it in & out.
  104.         - multi-file searches are backgroundable now as well.
  105. 1.0 - finalized 12/18/91; identical to version 1.0b4
  106.  
  107. Future enhancements
  108.    • Save the Progress window's position between compiles and between
  109.    launches
  110.    • Custom sound when a compile is finished
  111.    • Customize toggle key modifiers
  112.    • Control Panel interface for preferences
  113.  
  114. Please contact me if you find any bugs, or have any suggestions for
  115. improvement. Thanks for all the positive feedback that I've gotten!
  116.  
  117. Phil Shapiro
  118.  
  119. Internet: phils@chaos.cs.brandeis.edu
  120. AOL: PhilShap
  121. Postal:
  122. 70 Simpson Ave.
  123. Somerville, MA 02144